package com.lanlion.portlet.tool;

/**
 * 常量
 */
public class WechatConstants {

    public enum SignType {
        MD5, HMACSHA256
    }
    public static final int HTTP_OK     = 200;
    public static final String FAIL     = "FAIL";
    public static final String SUCCESS  = "SUCCESS";
    public static final String HMACSHA256 = "HMAC-SHA256";
    public static final String MD5 = "MD5";


    public static final String FIELD_SIGN = "sign";
    public static final String FIELD_SIGN_TYPE = "sign_type";
    public static final String MICROAPI_VERSION = "3.0";
    public static final String GET_CERTFICATES = "https://api.mch.weixin.qq.com/risk/getcertficates";
    public static final String SEND_MICROSHOP = "https://api.mch.weixin.qq.com/applyment/micro/submit";
    public static final String GETMICRO_STATE = "https://api.mch.weixin.qq.com/applyment/micro/getstate";

    //微信分账类型
    public static final String SHARE_FUNDS_MERCHANT_ID = "MERCHANT_ID";
    public static final String SHARE_FUNDS_PERSONAL_WECHATID = "PERSONAL_WECHATID";
    public static final String SHARE_FUNDS_PERSONAL_OPENID = "PERSONAL_OPENID";
    public static final String SHARE_FUNDS_PERSONAL_SUB_OPENID = "PERSONAL_SUB_OPENID";

    //微信分账接收方和子商户的关系
    public static final String SHARE_FUNDS_RELATION_SERVICE_PROVIDER = "SERVICE_PROVIDER";
    public static final String SHARE_FUNDS_RELATION_STORE = "STORE";
    public static final String SHARE_FUNDS_RELATION_STORE_OWNER = "STORE_OWNER";
    public static final String SHARE_FUNDS_RELATION_PARTNER = "PARTNER";
    public static final String SHARE_FUNDS_RELATION_HEADQUARTER = "HEADQUARTER";
    public static final String SHARE_FUNDS_RELATION_BRAND = "BRAND";
    public static final String SHARE_FUNDS_RELATION_DISTRIBUTOR = "DISTRIBUTOR";
    public static final String SHARE_FUNDS_RELATION_USER = "USER";
    public static final String SHARE_FUNDS_RELATION_SUPPLIER = "SUPPLIER";
    public static final String SHARE_FUNDS_RELATION_CUSTOM = "CUSTOM";

    //配置小微商户
    public static final String CONFIG_MICROSHOP_PAYMENT = "https://api.mch.weixin.qq.com/secapi/mch/addsubdevconfig";

    //小微商户配置信息
    public static final String GET_MICROSHOP_CONFIG = "https://api.mch.weixin.qq.com/secapi/mch/querysubdevconfig";


    //微信支付请求下单
    public static final String UNIFIEDORDER = "https://api.mch.weixin.qq.com/pay/unifiedorder";

    //微信订单查询
    public static final String ORDER_QUERY = "https://api.mch.weixin.qq.com/pay/orderquery";

    //微信退款
    public static final String REFUND = "https://api.mch.weixin.qq.com/secapi/pay/refund";

    //查询退款
    public static final String REFUND_QUERY = "https://api.mch.weixin.qq.com/pay/refundquery";

    //查询分账结果
    public static final String PROFITSHARINGQUERY = "https://api.mch.weixin.qq.com/pay/profitsharingquery";

    //添加分账接收方
    public static final String PROFITSHARINGADDRECEIVER = "https://api.mch.weixin.qq.com/pay/profitsharingaddreceiver";

    //请求单次分账
    public static final String PROFITSHARING = "https://api.mch.weixin.qq.com/secapi/pay/profitsharing";

    //完结分账
    public static final String PROFITSHARINGFINISH = "https://api.mch.weixin.qq.com/secapi/pay/profitsharingfinish";

    //企业付款到个人
    public static final String PAY2PERSON_FROM_COMPANY = "https://api.mch.weixin.qq.com/mmpaymkttransfers/promotion/transfers";

    //查询企业付款到个人结果
    public static final String PAY2PERSON_FROM_COMPANY_STATUS = "https://api.mch.weixin.qq.com/mmpaymkttransfers/gettransferinfo";

    //发放普通红包
    public static final String SEND_RED_PACKAGE = "https://api.mch.weixin.qq.com/mmpaymkttransfers/sendredpack";

    //发放裂变红包
    public static final String SEND_GROUP_RED_PACKAGE = "https://api.mch.weixin.qq.com/mmpaymkttransfers/sendgroupredpack";


    //获取红包发放信息
    public static final String GET_RED_PACKAGE_INFO = "https://api.mch.weixin.qq.com/mmpaymkttransfers/gethbinfo";


    //发送模板消息
    public static final String  SEND_TEMP_MSG="https://api.weixin.qq.com/cgi-bin/message/template/send?access_token=${1}";
}

